package controllers

import (
	"cashew.com/cashew_task/services"
	"github.com/beego/beego/v2/core/logs"
)

type JobTriggerController struct {
	BaseController
}

func (jtc *JobTriggerController) CleanUser() {
	logs.Info("#####CleanUser")
	jtc.initResult()

	err := services.CleanUsers()
	if err != nil {
		jtc.buildSystemErrorResult()
		return
	}
}

func (jtc *JobTriggerController) ExceptionUserHandle() {
	logs.Info("#####ExceptionUserHandle")
	jtc.initResult()

	err := services.ExceptionHandling()
	if err != nil {
		jtc.buildSystemErrorResult()
		return
	}
}
